﻿@model VehicleManagement.Models.Approval

@{
    ViewBag.Title = "EditApproval";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
<script type="text/javascript">
    $(function () {
        $.post("/Driver/GetDriverNameListByState", { state: 0 },
            function (data) {
                $("#DriverName").empty();
                $("#DriverName").append('<option>' + '</option>');
                $.each(data, function () {
                    $("#DriverName").append('<option>' + this + '</option>');
                });
                $("#DriverName").val('@Model.DriverName');
            });
            $.post("/CarInfo/GetCarsAvailable", { state: 0 },
            function (data) {
                $("#CarNumber").empty();
                $("#CarNumber").append('<option>' + '</option>');
                $.each(data, function () {
                    $("#CarNumber").append('<option>' + this + '</option>');
                });
                $("#CarNumber").val('@Model.CarNumber');
            });
    });
</script>
<div class="mas">
<div class="toptitle">
   司机负责人管理平台
</div>
@*<div class="car"></div>*@
@Html.Partial("_PartviewDriverManager")
<div class="rightshow">

@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
   <fieldset>
        <legend></legend>
       <div class="box">
        <div class="box-title">
            <span>@Html.ActionLink("返回审批表列表", "../Apply")</span>        
        </div>
        <div class="box-detail-nopic-edit" >
            <div class="box-detail1-linetype1 hide">
                <span class="labeldisplay">@Html.LabelFor(model => model.ApprovalID):</span>
                @Html.EditorFor(model => model.ApprovalID)
            </div>
            <div class="box-detail1-linetype1 hide">
                <span class="labeldisplay">@Html.LabelFor(model => model.ApplyID):</span>
                @Html.EditorFor(model => model.ApplyID)
            </div>
            <div class="box-detail1-linetype1">
                <span class="labeldisplay">@Html.LabelFor(model => model.ApplyState):</span>
                @Html.EditorFor(model => model.ApplyState)@Html.ValidationMessageFor(model => model.ApplyState)
            </div>   
            <div class="box-detail1-linetype1">
                <span class="labeldisplay">@Html.LabelFor(model => model.CarNumber):</span>
                 @Html.DropDownListFor(model => model.CarNumber, new SelectList(new[] { Model.CarNumber }, Model.CarNumber))
                @Html.ValidationMessageFor(model => model.CarNumber)
            </div>
            <div class="box-detail1-linetype1">
                <span class="labeldisplay">@Html.LabelFor(model => model.DriverName):</span>
                 @Html.DropDownListFor(model => model.DriverName, new SelectList(new[] { Model.DriverName }, Model.DriverName))
                @Html.ValidationMessageFor(model => model.DriverName) 
            </div>
            <div class="box-detail1-linetype1">
                <span class="labeldisplay">@Html.LabelFor(model => model.Priority):</span>
                @Html.EditorFor(model => model.Priority)@Html.ValidationMessageFor(model => model.Priority)
            </div>
            <div class="box-detail1-linetype1">
                <span class="labeldisplay">@Html.LabelFor(model => model.Reason):</span>
                @Html.EditorFor(model => model.Reason)@Html.ValidationMessageFor(model => model.Reason)
            </div>
            <div class="box-detail1-linetype1">
                <span class="labeldisplay">@Html.LabelFor(model => model.Remark):</span>
                @Html.TextAreaFor(model => model.Remark)
            </div>
            
            <input class="button" type="submit" value="修 改" />
        </div>
    </div>

    </fieldset>
}


</div>

<div class="clear"></div>
	
</div>

